import 'add_grid_net_bean.dart';

class Customerlist {
  int? total;
  int? current;
  List<CustomerListItem>? list;

  Customerlist({this.total, this.current, this.list});

  Customerlist.fromJson(Map<String, dynamic> json) {
    total = json['total'];
    current = json['current'];
    if (json['list'] != null) {
      list = <CustomerListItem>[];
      json['list'].forEach((v) {
        list!.add(new CustomerListItem.fromJson(v));
      });
    }
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['total'] = this.total;
    data['current'] = this.current;
    if (this.list != null) {
      data['list'] = this.list!.map((v) => v.toJson()).toList();
    }
    return data;
  }
}

class CustomerListItem {
  int? id;
  String? auditOpinion;
  String? customerName;
  String? phoneNumber;
  String? idNumber;
  String? idNumberPositive;
  String? idNumberNegative;
  String? bankCardNumber;
  String? bankName;
  String? bankCardPhoto;
  String? buildingAddress;
  String? remarks;
  String? houseTitleCertificate;
  String? gatePhoto;
  String? panoramicPhoto;
  String? other;
  int? auditStatus;
  String? auditBy;
  String? auditByName;
  String? auditDate;
  String? createDate;
  String? updateDate;
  String? createBy;
  String? createByName;
  String? updateBy;
  String? updateByName;
  int? status;
  int? customerInfoId;
  String? address;
  String? latitude;
  String? longitude;
  String? userName;
  int? period;

  CustomerListItem(
      {this.id,
        this.auditOpinion,
      this.customerName,
      this.phoneNumber,
      this.idNumber,
      this.idNumberPositive,
      this.idNumberNegative,
      this.bankCardNumber,
      this.bankCardPhoto,
      this.bankName,
      this.buildingAddress,
      this.remarks,
      this.houseTitleCertificate,
      this.gatePhoto,
      this.panoramicPhoto,
      this.other,
      this.auditStatus,
      this.auditBy,
      this.auditByName,
      this.auditDate,
      this.createDate,
      this.updateDate,
      this.createBy,
      this.createByName,
      this.updateBy,
      this.updateByName,
      this.status,
      this.customerInfoId,
      this.latitude,
      this.longitude,
      this.userName,
      this.period});

  CustomerListItem.fromJson(Map<String, dynamic> json) {
    id = json['id'];
    auditOpinion = json['auditOpinion'];
    customerName = json['customerName'];
    phoneNumber = json['phoneNumber'];
    idNumber = json['idNumber'];
    bankCardPhoto = json['bankCardPhoto'];
    idNumberPositive = json['idNumberPositive'];
    idNumberNegative = json['idNumberNegative'];
    bankCardNumber = json['bankCardNumber'];
    bankName = json['bankName'];
    buildingAddress = json['buildingAddress'];
    remarks = json['remarks'];
    houseTitleCertificate = json['houseTitleCertificate'];
    gatePhoto = json['gatePhoto'];
    panoramicPhoto = json['panoramicPhoto'];
    other = json['other'];
    auditStatus = json['auditStatus'];
    auditBy = json['auditBy'];
    auditByName = json['auditByName'];
    auditDate = json['auditDate'];
    createDate = json['createDate'];
    updateDate = json['updateDate'];
    createBy = json['createBy'];
    createByName = json['createByName'];
    updateBy = json['updateBy'];
    updateByName = json['updateByName'];
    status = json['status'];
    customerInfoId = json['customerInfoId'];
    address = json['address'];
    longitude = json['longitude'];
    latitude = json['latitude'];
    userName = json['userName'];
    period = json['period'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['id'] = this.id;
    data['auditOpinion'] = this.auditOpinion;
    data['customerName'] = this.customerName;
    data['phoneNumber'] = this.phoneNumber;
    data['idNumber'] = this.idNumber;
    data['idNumberPositive'] = this.idNumberPositive;
    data['idNumberNegative'] = this.idNumberNegative;
    data['bankCardNumber'] = this.bankCardNumber;
    data['bankName'] = this.bankName;
    data['bankCardPhoto'] = this.bankCardPhoto;
    data['buildingAddress'] = this.buildingAddress;
    data['remarks'] = this.remarks;
    data['houseTitleCertificate'] = this.houseTitleCertificate;
    data['gatePhoto'] = this.gatePhoto;
    data['panoramicPhoto'] = this.panoramicPhoto;
    data['other'] = this.other;
    data['auditStatus'] = this.auditStatus;
    data['auditBy'] = this.auditBy;
    data['auditByName'] = this.auditByName;
    data['auditDate'] = this.auditDate;
    data['createDate'] = this.createDate;
    data['updateDate'] = this.updateDate;
    data['createBy'] = this.createBy;
    data['createByName'] = this.createByName;
    data['updateBy'] = this.updateBy;
    data['updateByName'] = this.updateByName;
    data['status'] = this.status;
    data['customerInfoId'] = this.customerInfoId;
    data['address'] = this.address;
    data['latitude'] = this.latitude;
    data['longitude'] = this.longitude;
    data['userName'] = this.userName;
    data["period"] = this.period;
    return data;
  }
}

class ReconnaissanceLink {
  int? id;
  int? customerInfoId;
  String? userName;
  String? phoneNumber;
  String? surveyMethod;
  String? address;
  String? addressLongitude;
  String? addressLatitude;
  String? surveyDate;
  String? remarks;
  String? surveySheet;
  String? roughSketch;
  String? gatePhoto;
  String? panoramicPhoto;
  String? oppositeAnglesPhoto;
  String? externalDetailPhoto;
  String? other;
  int? auditStatus;
  String? auditBy;
  String? auditByName;
  String? auditDate;
  String? createDate;
  String? updateDate;
  String? createBy;
  String? createByName;
  String? updateBy;
  String? updateByName;
  int? status;
  String? areaName;
  String? areaCapacity;
  String? areaDistance;

  ReconnaissanceLink({
    this.id,
    this.customerInfoId,
    this.userName,
    this.phoneNumber,
    this.surveyMethod,
    this.address,
    this.addressLongitude,
    this.addressLatitude,
    this.surveyDate,
    this.surveySheet,
    this.remarks,
    this.roughSketch,
    this.gatePhoto,
    this.panoramicPhoto,
    this.oppositeAnglesPhoto,
    this.externalDetailPhoto,
    this.other,
    this.auditStatus,
    this.auditBy,
    this.auditByName,
    this.auditDate,
    this.createDate,
    this.updateDate,
    this.createBy,
    this.createByName,
    this.updateBy,
    this.updateByName,
    this.status,
    this.areaName,
    this.areaCapacity,
    this.areaDistance,
  });

  ReconnaissanceLink.fromJson(Map<String, dynamic> json) {
    id = json['id'];
    customerInfoId = json['customerInfoId'];
    userName = json['userName'];
    phoneNumber = json['phoneNumber'];
    surveyMethod = json['surveyMethod'];
    address = json['address'];
    addressLongitude = json['addressLongitude'];
    addressLatitude = json['addressLatitude'];
    surveyDate = json['surveyDate'];
    surveySheet = json['surveySheet'];
    remarks = json['remarks'];
    roughSketch = json['roughSketch'];
    gatePhoto = json['gatePhoto'];
    panoramicPhoto = json['panoramicPhoto'];
    oppositeAnglesPhoto = json['oppositeAnglesPhoto'];
    externalDetailPhoto = json['externalDetailPhoto'];
    other = json['other'];
    auditStatus = json['auditStatus'];
    auditBy = json['auditBy'];
    auditByName = json['auditByName'];
    auditDate = json['auditDate'];
    createDate = json['createDate'];
    updateDate = json['updateDate'];
    createBy = json['createBy'];
    createByName = json['createByName'];
    updateBy = json['updateBy'];
    updateByName = json['updateByName'];
    status = json['status'];
    areaName = json['areaName'];
    areaCapacity = json['areaCapacity'];
    areaDistance = json['areaDistance'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['id'] = this.id;
    data['customerInfoId'] = this.customerInfoId;
    data['userName'] = this.userName;
    data['phoneNumber'] = this.phoneNumber;
    data['surveyMethod'] = this.surveyMethod;
    data['address'] = this.address;
    data['addressLongitude'] = this.addressLongitude;
    data['addressLatitude'] = this.addressLatitude;
    data['surveyDate'] = this.surveyDate;
    data['surveySheet'] = this.surveySheet;
    data['remarks'] = this.remarks;
    data['roughSketch'] = this.roughSketch;
    data['gatePhoto'] = this.gatePhoto;
    data['panoramicPhoto'] = this.panoramicPhoto;
    data['oppositeAnglesPhoto'] = this.oppositeAnglesPhoto;
    data['externalDetailPhoto'] = this.externalDetailPhoto;
    data['other'] = this.other;
    data['auditStatus'] = this.auditStatus;
    data['auditBy'] = this.auditBy;
    data['auditByName'] = this.auditByName;
    data['auditDate'] = this.auditDate;
    data['createDate'] = this.createDate;
    data['updateDate'] = this.updateDate;
    data['createBy'] = this.createBy;
    data['createByName'] = this.createByName;
    data['updateBy'] = this.updateBy;
    data['updateByName'] = this.updateByName;
    data['status'] = this.status;
    data['areaName'] = this.areaName;
    data['areaCapacity'] = this.areaCapacity;
    data['areaDistance'] = this.areaDistance;
    return data;
  }
}

class DesignDrawLink {
  int? id;
  int? customerInfoId;
  String? componentNumber;
  String? designDrawPhoto;
  String? billMaterials;
  String? cadFile;
  String? remarks;
  String? other;
  int? auditStatus;
  String? auditDate;
  String? auditByName;
  String? auditBy;
  String? createDate;
  String? updateDate;
  String? createBy;
  String? createByName;
  String? updateBy;
  String? updateByName;
  String? capacity;
  String? inverterModel;

  DesignDrawLink(
      {this.id,
      this.customerInfoId,
      this.componentNumber,
      this.designDrawPhoto,
      this.billMaterials,
      this.cadFile,
      this.remarks,
      this.other,
      this.auditStatus,
      this.auditDate,
      this.auditByName,
      this.auditBy,
      this.createDate,
      this.updateDate,
      this.createBy,
      this.createByName,
      this.updateBy,
      this.updateByName,
      this.capacity,
      this.inverterModel});

  DesignDrawLink.fromJson(Map<String, dynamic> json) {
    id = json['id'];
    customerInfoId = json['customerInfoId'];
    componentNumber = json['componentNumber'];
    designDrawPhoto = json['designDrawPhoto'];
    billMaterials = json['billMaterials'];
    cadFile = json['cadFile'];
    remarks = json['remarks'];
    other = json['other'];
    auditStatus = json['auditStatus'];
    auditDate = json['auditDate'];
    auditByName = json['auditByName'];
    auditBy = json['auditBy'];
    createDate = json['createDate'];
    updateDate = json['updateDate'];
    createBy = json['createBy'];
    createByName = json['createByName'];
    updateBy = json['updateBy'];
    updateByName = json['updateByName'];
    capacity = json['capacity'];
    inverterModel = json['inverterModel'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['id'] = this.id;
    data['customerInfoId'] = this.customerInfoId;
    data['componentNumber'] = this.componentNumber;
    data['designDrawPhoto'] = this.designDrawPhoto;
    data['billMaterials'] = this.billMaterials;
    data['cadFile'] = this.cadFile;
    data['remarks'] = this.remarks;
    data['other'] = this.other;
    data['auditStatus'] = this.auditStatus;
    data['auditDate'] = this.auditDate;
    data['auditByName'] = this.auditByName;
    data['auditBy'] = this.auditBy;
    data['createDate'] = this.createDate;
    data['updateDate'] = this.updateDate;
    data['createBy'] = this.createBy;
    data['createByName'] = this.createByName;
    data['updateBy'] = this.updateBy;
    data['updateByName'] = this.updateByName;
    data['capacity'] = this.capacity;
    data['inverterModel'] = this.inverterModel;
    return data;
  }
}

class StartedApproval {
  String? remarks;
  int? id;
  int? customerInfoId;
  String? contract;
  String? propertyCertificate;
  String? copyIdCard;
  String? report;
  String? construction;
  String? designPhoto;
  String? loadReport;
  String? other;

  StartedApproval({
    this.remarks,
    this.id,
    this.customerInfoId,
    this.contract,
    this.propertyCertificate,
    this.copyIdCard,
    this.other,
    this.report,
    this.construction,
    this.designPhoto,
    this.loadReport,
  });

  StartedApproval.fromJson(Map<String, dynamic> json) {
    remarks = json['remarks'];
    id = json['id'];
    customerInfoId = json['customerInfoId'];
    contract = json['contract'];
    propertyCertificate = json['propertyCertificate'];
    copyIdCard = json['copyIdCard'];
    other = json['other'];
    report = json['report'];
    construction = json['construction'];
    designPhoto = json['designPhoto'];
    loadReport = json['loadReport'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['remarks'] = this.remarks;
    data['id'] = this.id;
    data['customerInfoId'] = this.customerInfoId;
    data['contract'] = this.contract;
    data['propertyCertificate'] = this.propertyCertificate;
    data['copyIdCard'] = this.copyIdCard;
    data['other'] = this.other;
    data['report'] = this.report;
    data['construction'] = this.construction;
    data['designPhoto'] = this.designPhoto;
    data['loadReport'] = this.loadReport;
    return data;
  }
}

class ConstructionLink {
  int? id;
  int? customerInfoId;
  String? materialsEntranceDate;
  String? materialsEntrancePhoto;
  String? classMeetingPhoto;
  String? safetyProtectionPhoto;
  String? stentInstallPhoto;
  String? componentInstallPhoto;
  String? inverterInstallPhoto;
  String? stentInstallGround;
  String? inverterInstallGround;
  String? cableLayingPhoto;
  String? componentFinishPhoto;
  String? voltagePhoto;
  String? resistancePhoto;
  String? startDate;
  String? address;
  String? addressLongitude;
  String? addressLatitude;
  String? constructionUser;
  String? safetyUser;
  String? inverterPhoto;
  String? componentNumber;
  String? endDate;
  String? remarks;
  String? other;

  ConstructionLink(
      {this.id,
      this.customerInfoId,
      this.materialsEntranceDate,
      this.materialsEntrancePhoto,
      this.classMeetingPhoto,
      this.safetyProtectionPhoto,
      this.stentInstallPhoto,
      this.componentInstallPhoto,
      this.inverterInstallPhoto,
      this.stentInstallGround,
      this.inverterInstallGround,
      this.cableLayingPhoto,
      this.componentFinishPhoto,
      this.voltagePhoto,
      this.resistancePhoto,
      this.startDate,
      this.address,
      this.addressLongitude,
      this.addressLatitude,
      this.constructionUser,
      this.safetyUser,
      this.inverterPhoto,
      this.componentNumber,
      this.endDate,
      this.remarks,
      this.other});

  ConstructionLink.fromJson(Map<String, dynamic> json) {
    id = json['id'];
    customerInfoId = json['customerInfoId'];
    materialsEntranceDate = json['materialsEntranceDate'];
    if (json['materialsEntrancePhoto'] != null) {
      materialsEntrancePhoto = json['materialsEntrancePhoto'];
    }
    if (json['classMeetingPhoto'] != null) {
      classMeetingPhoto = json['classMeetingPhoto'];
    }
    if (json['safetyProtectionPhoto'] != null) {
      safetyProtectionPhoto = json['safetyProtectionPhoto'];
    }
    if (json['stentInstallPhoto'] != null) {
      stentInstallPhoto = json['stentInstallPhoto'];
    }
    if (json['componentInstallPhoto'] != null) {
      componentInstallPhoto = json['componentInstallPhoto'];
    }
    if (json['inverterInstallPhoto'] != null) {
      inverterInstallPhoto = json['inverterInstallPhoto'];
    }
    if (json['stentInstallGround'] != null) {
      stentInstallGround = json['stentInstallGround'];
    }
    if (json['voltagePhoto'] != null) {
      voltagePhoto = json['voltagePhoto'];
    }
    if (json['resistancePhoto'] != null) {
      resistancePhoto = json['resistancePhoto'];
    }
    if (json['inverterInstallGround'] != null) {
      inverterInstallGround = json['inverterInstallGround'];
    }
    if (json['cableLayingPhoto'] != null) {
      cableLayingPhoto = json['cableLayingPhoto'];
    }
    if (json['componentFinishPhoto'] != null) {
      componentFinishPhoto = json['componentFinishPhoto'];
    }
    if (json['inverterPhoto'] != null) {
      inverterPhoto = json['inverterPhoto'];
    }
    if (json['other'] != null) {
      other = json['other'];
    }
    startDate = json['startDate'];
    address = json['address'];
    addressLongitude = json['addressLongitude'];
    addressLatitude = json['addressLatitude'];
    constructionUser = json['constructionUser'];
    safetyUser = json['safetyUser'];

    componentNumber = json['componentNumber'];
    endDate = json['endDate'];
    remarks = json['remarks'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['id'] = this.id;
    data['customerInfoId'] = this.customerInfoId;
    data['materialsEntranceDate'] = this.materialsEntranceDate;
    data['classMeetingPhoto'] = this.classMeetingPhoto;
    data['safetyProtectionPhoto'] = this.safetyProtectionPhoto;
    data['stentInstallPhoto'] = this.stentInstallPhoto;
    data['componentInstallPhoto'] = this.componentInstallPhoto;
    data['stentInstallGround'] = this.stentInstallGround;
    data['cableLayingPhoto'] = this.cableLayingPhoto;
    data['componentFinishPhoto'] = this.componentFinishPhoto;
    data['materialsEntrancePhoto'] = this.materialsEntrancePhoto;
    data['materialsEntrancePhoto'] = this.materialsEntrancePhoto;
    data['materialsEntrancePhoto'] = this.materialsEntrancePhoto;
    data['inverterPhoto'] = this.materialsEntrancePhoto;
    data['voltagePhoto'] = this.voltagePhoto;
    data['resistancePhoto'] = this.resistancePhoto;
    data['other'] = this.other;
    data['startDate'] = this.startDate;
    data['address'] = this.address;
    data['addressLongitude'] = this.addressLongitude;
    data['addressLatitude'] = this.addressLatitude;
    data['constructionUser'] = this.constructionUser;
    data['safetyUser'] = this.safetyUser;
    data['componentNumber'] = this.componentNumber;
    data['endDate'] = this.endDate;
    data['remarks'] = this.remarks;
    return data;
  }
}

class GridConnectedLink {
  int? id;
  int? customerInfoId;
  String? gridConnectedAddress;
  String? capacity;
  String? electricNumber;
  String? correlationNumber;
  String? contractSignDate;
  String? remarks;
  String? recordForm;
  String? other;
  String? applicationProcess;
  String? gridConnectedAddressTwo;
  String? electricNumberTwo;
  String? correlationNumberTwo;
  String? gridConnectedAddressThree;
  String? electricNumberThree;
  String? correlationNumberThree;
  List<GridConnectedPointDTOS>? gridConnectedPointDTOS;

  GridConnectedLink({
    this.id,
    this.customerInfoId,
    this.capacity,
    this.gridConnectedAddress,
    this.electricNumber,
    this.correlationNumber,
    this.contractSignDate,
    this.remarks,
    this.recordForm,
    this.other,
    this.applicationProcess,
    this.gridConnectedAddressTwo,
    this.electricNumberTwo,
    this.correlationNumberTwo,
    this.gridConnectedAddressThree,
    this.electricNumberThree,
    this.correlationNumberThree,
    this.gridConnectedPointDTOS
  });

  GridConnectedLink.fromJson(Map<String, dynamic> json) {
    id = json['id'];
    customerInfoId = json['customerInfoId'];
    capacity = json['capacity'];
    gridConnectedAddress = json['gridConnectedAddress'];
    electricNumber = json['electricNumber'];
    correlationNumber = json['correlationNumber'];
    contractSignDate = json['contractSignDate'];

    gridConnectedAddressTwo = json['gridConnectedAddressTwo'];
    electricNumberTwo = json['electricNumberTwo'];
    correlationNumberTwo = json['correlationNumberTwo'];
    gridConnectedAddressThree = json['gridConnectedAddressThree'];
    electricNumberThree = json['electricNumberThree'];
    correlationNumberThree = json['correlationNumberThree'];

    remarks = json['remarks'];
    if (json['recordForm'] != null) {
      recordForm = json['recordForm'];
    }
    if (json['other'] != null) {
      other = json['other'];
    }
    applicationProcess = json['applicationProcess'];
    if (json['gridConnectedPointDTOS'] != null) {
      gridConnectedPointDTOS = <GridConnectedPointDTOS>[];
      json['gridConnectedPointDTOS'].forEach((v) {
        gridConnectedPointDTOS!.add(GridConnectedPointDTOS.fromJson(v));
      });
    }
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['id'] = this.id;
    data['customerInfoId'] = this.customerInfoId;
    data['capacity'] = this.capacity;
    data['gridConnectedAddress'] = this.gridConnectedAddress;
    data['electricNumber'] = this.electricNumber;
    data['correlationNumber'] = this.correlationNumber;
    data['contractSignDate'] = this.contractSignDate;
    data['remarks'] = this.remarks;
    data['recordForm'] = this.recordForm;
    data['other'] = this.other;
    data['applicationProcess'] = this.applicationProcess;
    data['gridConnectedAddressTwo'] = this.gridConnectedAddressTwo;
    data['electricNumberTwo'] = this.electricNumberTwo;
    data['correlationNumberTwo'] = this.correlationNumberTwo;
    data['gridConnectedAddressThree'] = this.gridConnectedAddressThree;
    data['electricNumberThree'] = this.electricNumberThree;
    data['correlationNumberThree'] = this.correlationNumberThree;
    if (this.gridConnectedPointDTOS != null) {
      data['gridConnectedPointDTOS'] =
          this.gridConnectedPointDTOS!.map((v) => v.toJson()).toList();
    }
    return data;
  }
}

class Acceptance {
  int? id;
  int? customerInfoId;
  String? remarks;
  String? reportFile;
  String? other;

  Acceptance({
    this.id,
    this.customerInfoId,
    this.remarks,
    this.reportFile,
    this.other,
  });

  Acceptance.fromJson(Map<String, dynamic> json) {
    id = json['id'];
    customerInfoId = json['customerInfoId'];
    remarks = json['remarks'];
    if (json['reportFile'] != null) {
      reportFile = json['reportFile'];
    }
    if (json['other'] != null) {
      other = json['other'];
    }
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['id'] = this.id;
    data['customerInfoId'] = this.customerInfoId;
    data['remarks'] = this.remarks;
    data['reportFile'] = this.reportFile;
    data['other'] = this.other;
    return data;
  }
}
